package cn.wolfcode.trip.base.mapper;

import cn.wolfcode.trip.base.domain.DynamicContent;
import cn.wolfcode.trip.base.query.DynamicContentQueryObject;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface DynamicContentMapper {
    int deleteByPrimaryKey(Long id);

    int insert(DynamicContent record);

    DynamicContent selectByPrimaryKey(Long id);

    List<DynamicContent> selectAll();

    int updateByPrimaryKey(DynamicContent record);

    /**
     * 朋友圈动态，分页查询
     * @param qo
     * @return
     */
    List selectForList(DynamicContentQueryObject qo);

    /**
     * 维护单条动态和可访问用户的关系
     * @param
     * @param
     */
    void insertRelation(@Param("dynamicContentId") Long dynamicContentId, @Param("visitId") String visitId);
}